package com.zf.generator.test;

import java.io.BufferedReader;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.FileReader;

import org.eclipse.core.resources.IProject;

import com.zf.generator.utils.SysFileUtil;

public class FileTest1 {

	/**
	 * @param args
	 */
	public static void main(String[] args) throws Exception {
		String s="com.zf.generator.bean.ClassNameInfo.java";
		File file= new File(SysFileUtil.getFileRealPath(s));
		
		String packageFullPath="com.zf.blog.abc";
		
//		System.out.println(SysFileUtil.convertFileToString(file));
//		IProject p=SysFileUtil.getCurrentProject();
//		System.out.println(p.getName());
		
//		System.out.println(System.getProperty("user.dir"));
//		
//		String userDir=System.getProperty("user.dir");
//		//项目名称
//		String  name =  userDir.substring(userDir.lastIndexOf("\\")+1,userDir.length());
//		
//		System.out.println( name);
		System.out.println(SysFileUtil.getPackageRealPath(packageFullPath));
		SysFileUtil.createPackage(packageFullPath);
	}

}
